The present invention relates generally to the field of indexing data, and more particularly to suspending a database index in a data processing system.
Computer databases allow the storage of digital data in an organized format that allows searches to retrieve a particular subset of data utilizing specialized commands in a query language, such as Structured Query Language (SQL). SQL enables data entry, manipulation, and deletion within database tables. Client applications may generate SQL statements based on user input. Stored database procedures may include SQL statements, which run either on a schedule or on request by a Database Administrator (DBA). The SQL is executed by a Database Management System (DBMS), which is a software system designed to control access and allow administration of a database. A query describes the data being requested from the database, but does not define the best path for retrieving that data from the database. A query optimizer defines the most efficient way to execute a given query within a database system.
In a database environment, the query optimizer utilizes database indices to determine the best path for a DBMS to access specific data in a database table. Indices enable a query to locate data quickly without having to search entire rows of a database table. A database index is a data structure that improves the speed of data retrieval operations on a database table by storing a copy of one or more selected columns of data from a table with a pointer back to the complete row of data from which the column item was copied. Some indices are created for special use and only create entries for records satisfying a selected condition, function, or expression, such as for a specific customer. In some cases, databases may have multiple indices covering a single database table. Each index is stored as a separate searchable entity from the data in the database tables. The DBMS maintains each index as information is inserted into, removed from, and updated in the rows of the database tables. When processing large volumes of updates to a database, the DBA may delete an index, and then rebuild the index at the end of processing rather than performing incremental updates during the load.